import ant_en from "ant-design-vue/es/locale/en_US";
import ant_zhCN from "ant-design-vue/es/locale/zh_CN";
import ant_zhTW from "ant-design-vue/es/locale/zh_TW";
import ant_koKR from "ant-design-vue/es/locale/ko_KR";
import ant_jaJP from "ant-design-vue/es/locale/ja_JP";
import { IMOptionsType } from "@/types/dict";

import message_zhCN from "./locales/zhCN";
import message_zhTW from "./locales/zhTW";
import message_koKR from "./locales/koKR";
import message_jaJP from "./locales/jaJP";
import message_en from "./locales/en";
export const messageLanguage = {
  en: message_en,
  "zh-cn": message_zhCN,
  "zh-tw": message_zhTW,
  "ko-kr": message_koKR,
  "ja-jp": message_jaJP,
};
export const AntLanguage = {
  en: ant_en,
  "zh-cn": ant_zhCN,
  "zh-tw": ant_zhTW,
  "ko-kr": ant_koKR,
  "ja-jp": ant_jaJP,
};
export const language_convert = reactive<any>({
  en: "en",
  "zh-cn": "zh-CN",
  "zh-tw": "zh-TW",
  "ko-kr": "ko",
  "ja-jp": "ja",
});
export const languageMap = reactive<Array<IMOptionsType>>([
  {
    value: "en",
    label: "English",
  },
  {
    value: "zh-cn",
    label: "中文简体",
  },
  /*
  {
    label: "中文繁体",
    value: "zh-tw",
  },
  {
    value: "ko-kr",
    label: "한국어",
  },
  {
    value: "ja-jp",
    label: "日本語",
  },*/
]);

export const languageIcons = {
  en: (
    <svg
      viewBox="0 0 1024 1024"
      xmlns="http://www.w3.org/2000/svg"
      width="16"
      height="16"
    >
      <path
        d="M580 477.7h-9.8l37.6 209.1c24.8-8.8 47.4-22.2 67.5-39.6-20.6-24.8-37.1-52.5-50-81.9l39.6-5.2c10.8 22.2 23.2 42.2 37.6 59.3 29.3-35.5 51.5-82.9 67.5-142.2l-190 0.5z m149.9 169.5c22.7 19.6 48.4 34 77.2 42.7l18.1 5.7-10.8 38.6-18.1-5.7c-34.5-10.8-66.5-28.8-93.7-53.1-25.3 22.7-55.1 40.2-87.5 51l25.3 141.1H489.8l-20.1 92.2h472.4c22.2 0 40.2-18.1 40.2-40.2v-683c0-22.2-18.1-40.2-40.2-40.2H520.3l31.4 175.2-1-0.5 3.6 19.1 0.5-2.6 8.8 50H661v-40.2h75.3v40.2H862v40.2h-52.5c-17.7 70.6-44.6 127.3-79.6 169.5z m-281.3 220H82.3C38 867.2 2 831.1 2 786.8V104.2c0-44.8 36-80.3 80.3-80.3h401.8l24.8 132.4h432.8c44.3 0 80.3 36 80.3 80.3v683.1c0 44.3-36 80.3-80.3 80.3H419.8l28.8-132.8zM259.1 558.1v-42.2h-79.3v-62.4h73.7v-41.7h-73.7v-53.1h79.3V317H133.3v241.1h125.8z m193.6 0V437.5c0-21.7-5.2-38.6-15-50.5s-24.8-17.5-44.3-17.5c-11.4 0-21.7 2.1-30.4 6.7s-16 11.9-20.6 20.6h-2.6l-6.2-23.7h-35V558h45.3v-87c0-21.7 3.1-37.1 8.8-46.9 5.7-9.3 15-13.9 27.8-13.9 9.3 0 16 3.1 20.6 9.8 4.1 6.7 6.7 16.5 6.7 29.8V558l44.9 0.1z"
        p-id="9028"
        fill="#4E5969"
      ></path>
    </svg>
  ),
  "zh-cn": (
    <svg
      viewBox="0 0 1070 1024"
      xmlns="http://www.w3.org/2000/svg"
      width="16.71875"
      height="16"
    >
      <path
        d="M232.58156522 358.13286957C244.86956522 394.4626087 265.17147826 425.984 293.48730435 453.76556522c24.04173913-26.17878261 42.2066087-58.23443478 53.96034782-95.63269565H232.58156522z"
        p-id="8655"
        fill="#4E5969"
      ></path>
      <path
        d="M981.61530435 143.36h-448.77913044L507.19165217 6.05495652h-416.72347826c-45.94643478 0-83.34469565 37.39826087-83.34469565 83.34469565v708.42991305c0 45.94643478 37.39826087 83.34469565 83.34469565 83.34469565h379.85947826l-30.45286956 137.30504348h541.74052174c45.94643478 0 83.34469565-37.39826087 83.34469565-83.34469565V226.70469565c0-45.94643478-37.39826087-83.34469565-83.34469565-83.34469565zM415.83304348 564.35756522c-49.152-18.16486957-89.75582609-41.13808696-122.34573913-67.85113044-34.19269565 30.45286957-76.93356522 52.89182609-126.61982609 66.7826087l-17.09634783-28.31582609c48.61773913-12.82226087 89.22156522-32.05565217 121.2772174-59.30295652-33.12417391-33.65843478-56.0973913-72.65947826-68.91965218-117.00313044h-46.48069565v-32.05565217H276.92521739c-7.47965217-13.89078261-17.09634783-27.24730435-28.31582609-40.06956522l32.05565218-11.75373913c11.21947826 14.42504348 21.37043478 31.5213913 30.45286956 51.28904348h115.9346087v32.05565218h-46.48069565c-14.95930435 45.94643478-36.32973913 84.41321739-64.64556522 115.40034782 31.5213913 25.11026087 71.05669565 45.94643478 117.5373913 63.04278261l-17.63060869 27.78156522z m607.45460869 370.24278261c0 22.97321739-18.69913043 41.67234783-41.67234782 41.67234782H492.23234783l20.83617391-95.63269565h156.53843478l-89.22156522-497.39686957-0.53426087 2.67130435-3.73982608-19.76765217 1.06852174 0.53426087-32.58991305-181.64869565H982.14956522c22.97321739 0 41.67234783 18.69913043 41.67234782 41.67234782v707.89565218z"
        p-id="8656"
        fill="#4E5969"
      ></path>
      <path
        d="M684.56626087 541.38434783h114.86608696v-30.45286957h-114.86608696V450.02573913h122.34573913v-30.45286956h-158.14121739v219.04695652h162.94956522V608.16695652h-127.15408696v-66.78260869z m239.88313043-65.71408696c-9.61669565 0-18.16486957 1.60278261-26.1787826 5.87686956-7.47965217 3.73982609-14.95930435 9.61669565-20.83617392 17.09634783V479.94434783h-34.72695652v158.67547826h34.72695652v-95.63269566c1.06852174-12.82226087 5.3426087-22.43895652 12.82226087-29.38434782 6.41113043-5.87686957 13.89078261-9.08243478 22.43895652-9.08243478 24.04173913 0 35.79547826 12.82226087 35.79547826 39.00104347v94.56417392h34.72695653v-97.76973913c1.06852174-43.27513043-19.2333913-64.64556522-58.76869566-64.64556522z"
        p-id="8657"
        fill="#4E5969"
      ></path>
    </svg>
  ),
  "zh-tw": (
    <svg
      viewBox="0 0 1024 1024"
      xmlns="http://www.w3.org/2000/svg"
      width="16"
      height="16"
    >
      <path
        d="M746.5472 115.5072H208.896A133.888 133.888 0 0 1 323.2768 51.2h428.6464a214.3232 214.3232 0 0 1 214.3232 214.3232v466.176c0 50.688-28.16 94.7712-69.632 117.504v-583.68a150.016 150.016 0 0 0-150.016-150.016zM295.0656 526.4896c-0.8192 6.2464-1.5872 12.1856-2.2016 17.7664h114.176c2.048-13.824 4.096-30.208 5.632-46.592H343.04c15.872 9.216 33.28 22.016 41.984 32.768l-14.336 13.824c-9.216-11.264-27.648-25.6-44.032-35.328l12.288-11.264h-40.448c-0.9216 9.7792-2.2016 19.5584-3.4304 28.8256zM417.792 440.2688l0.512-7.168h-112.64l-1.024 9.6768c-1.2288 11.1104-2.56 22.8864-4.096 34.4064H373.76c-8.192-10.752-25.6-23.04-39.936-31.232l13.312-12.8c15.36 8.192 33.28 20.48 41.984 30.72l-13.312 13.312h38.912c1.28-12.3392 2.2016-25.088 3.072-36.9152z"
        p-id="9260"
        fill="#4E5969"
      ></path>
      <path
        d="M618.496 409.6h-84.48l-2.048 3.584c11.264 26.112 26.112 49.664 44.544 70.144 18.432-20.48 32.768-45.056 41.984-73.728z"
        p-id="9261"
        fill="#4E5969"
      ></path>
      <path
        d="M194.6624 158.3616A117.8624 117.8624 0 0 0 76.8 276.224v578.7136A117.8624 117.8624 0 0 0 194.6624 972.8h541.184a117.8624 117.8624 0 0 0 117.8624-117.8624V276.224a117.8624 117.8624 0 0 0-117.8624-117.8624H194.6624zM233.472 773.632c45.056-13.312 93.696-34.304 123.904-56.32l33.792 14.336c-33.792 26.624-86.016 52.224-129.024 68.096-6.144-7.168-19.456-19.968-28.672-26.112z m411.648-54.784c-8.192-8.704-18.944-18.432-32.256-29.184l-125.44 8.192v69.12c0 19.968-4.096 28.672-19.456 33.792-14.6432 5.12-36.1984 5.12-67.8912 5.12H391.68c-2.56-10.24-8.192-22.528-13.312-31.744 29.184 0.512 54.272 0.512 61.44 0 7.68 0 9.728-2.048 9.728-8.192v-65.536c-145.408 9.216-164.864 11.776-178.176 16.896-1.536-7.168-6.144-23.552-9.728-32.768 16.896-1.536 38.4-6.656 66.048-16.384 15.36-5.12 48.128-16.384 87.04-31.744-84.48 4.608-97.792 6.656-105.984 9.216-1.536-6.656-6.144-22.016-9.216-30.208 8.704-1.024 18.432-3.072 30.72-7.68 11.776-4.096 50.176-19.968 80.896-40.448H258.56c3.072-18.432 6.656-42.496 9.728-67.584H230.4v-24.576h40.448c2.56-20.48 4.608-41.472 6.144-59.904-8.192 8.704-16.384 17.408-25.088 24.576-6.144-5.12-19.456-14.336-27.648-18.432 28.672-20.48 53.248-51.2 67.584-83.456l30.72 7.168c-2.048 5.12-5.12 11.264-8.192 16.896h155.136v26.112H297.984c-4.608 7.68-10.24 14.848-16.384 22.016h168.448c-1.536 19.968-3.584 42.496-5.632 65.024h35.84v24.576h-37.888c-1.536 15.872-3.072 31.744-5.12 44.544h27.648v23.04h-41.984l18.944 15.872c-19.456 10.752-40.448 20.992-60.416 29.184l96.768-4.096 7.3216-3.6864c17.1008-8.4992 34.4064-17.152 50.5344-26.5216l22.528 25.088a1133.056 1133.056 0 0 1-171.52 72.704l191.488-11.264c-13.312-9.216-26.624-17.92-39.424-25.088l25.088-18.432c37.888 21.504 84.48 53.76 107.52 77.312l-26.624 20.48z m9.216 77.824c-27.648-17.92-82.432-44.032-126.464-60.416l26.624-19.968c43.008 15.36 98.304 39.936 128.512 58.88l-28.672 21.504z m32.768-415.744V409.6h-34.816c-11.264 37.888-29.696 69.632-53.248 95.744 27.136 23.04 60.416 40.448 98.304 50.688-7.68 7.168-17.408 19.968-22.016 29.184-38.4-12.8-71.68-32.256-99.84-57.856-25.088 20.992-53.76 37.888-87.04 51.712-4.096-6.656-14.336-19.968-21.504-25.6 33.28-12.288 62.976-28.16 87.552-48.128-16.384-18.944-29.696-40.448-40.96-63.488-8.192 10.752-16.384 20.48-25.6 28.672-4.608-6.144-16.896-17.92-24.576-23.04 29.696-25.6 51.712-65.024 63.488-107.52l33.28 6.144c-3.584 12.288-7.68 23.552-12.288 34.816h139.264z"
        p-id="9262"
        fill="#4E5969"
      ></path>
    </svg>
  ),
  "ko-kr": (
    <svg
      viewBox="0 0 1024 1024"
      xmlns="http://www.w3.org/2000/svg"
      width="16"
      height="16"
    >
      <path
        d="M620.089 295.822V180.907H28.444v114.915H620.09z m-48.925 208.214c0 108.088-98.986 191.146-244.622 191.146-145.635 0-244.622-83.058-244.622-191.146 0-106.952 97.849-191.147 244.622-191.147 145.636 0 244.622 84.195 244.622 191.147zM175.218 138.809h304.924V28.444H175.218V138.81zM832.853 0v341.333h136.534v122.88H832.853V763.45H683.804V0h149.05z m20.48 996.693H155.876V727.04h154.737v150.187h542.72v119.466zM230.97 504.036c0 42.097 38.684 79.644 95.573 79.644 58.027 0 96.711-37.547 96.711-79.644 0-39.823-38.684-81.92-96.71-81.92-56.89 0-95.574 42.097-95.574 81.92z"
        p-id="9813"
        fill="#4E5969"
      ></path>
    </svg>
  ),
  "ja-jp": (
    <svg
      viewBox="0 0 1024 1024"
      xmlns="http://www.w3.org/2000/svg"
      p-id="9534"
      width="16"
      height="16"
    >
      <path
        d="M656.042667 345.429333h-56.832v160.426667h59.221333c69.802667 0 102.4-26.624 102.4-84.138667s-35.498667-76.288-104.789333-76.288z"
        fill="#4E5969"
        p-id="9535"
      ></path>
      <path
        d="M873.472 49.664H150.528a100.693333 100.693333 0 0 0-100.864 100.864v722.944a100.693333 100.693333 0 0 0 100.864 100.864h722.944a100.693333 100.693333 0 0 0 100.864-100.864V150.528a100.693333 100.693333 0 0 0-100.864-100.864zM447.829333 592.725333c0 78.165333-38.229333 141.141333-126.634666 141.141334a133.802667 133.802667 0 0 1-126.122667-72.192l47.957333-34.133334c18.261333 34.133333 41.984 47.274667 70.485334 47.274667 43.690667 0 65.536-23.552 65.536-87.552V290.133333h68.266666zM665.6 560.810667h-66.389333v165.205333h-68.266667V290.133333h132.096c96.938667 0 166.229333 33.28 166.229333 131.413334-0.341333 95.402667-69.632 139.264-163.669333 139.264z"
        fill="#4E5969"
        p-id="9536"
      ></path>
    </svg>
  ),
};
